package Exercises;

import java.util.Scanner;

public class Task4 {

	public static void main(String[] args) {
		Scanner sc = new Scanner (System.in);

		int a = 0;
		int c = 0;
		
		while(true)
		{
			
		System.out.println("Add a number: ");	
			a = sc.nextInt();
				if(a%2==0)
				{
					c++;
				}
			if(a<0)
			{
				break;
			}
		
		}
		
		System.out.println("You enter "+ c + " even numbers");
		
		
	}

}
